package com.imoocdl.exception;

import com.imoocdl.enums.ResultEnum;
import lombok.Data;

/**
 * Created by pc on 2018/3/31.
 */
@Data
public class SellException extends  RuntimeException {
    private Integer code;

    public SellException(ResultEnum resultEnum) {
        super(resultEnum.getMessage());
        this.code = resultEnum.getCode();
    }

    public SellException(Integer code, String  Message) {
        super(Message);
        this.code = code;
    }
}
